package com.qf.j2112.mapper;

import com.qf.j2112.po.Order;
import com.qf.j2112.po.OrderItem;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

public interface OrderMapper {

    int addOneOrder(Order order);

    List<Order> findAllOrder(int uid);

    Order findOneByCdk(String cdk);

    int finishOrder(String cdk);

    List<OrderItem> findAllOrderItem(int oid);

    int addOneItem(OrderItem orderItem);

    int isOrderPay(String trade);

    List<Order> findAll();

    int countOrder();

    //找到未支付的订单
    List<Order> findUnpaidOrder();

    //让订单失效
    int orderFailed(Order order);
}
